<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

/**
 * Class CreateMedicalDrugType
 * 药品分类，
 */
class CreateMedicalDrugType extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('st_medical_medical_drug_type', function (Blueprint $table) {
            $table->increments('id');
            $table->string('name',20)->comment("分类名称");
            $table->unsignedTinyInteger('parent_type')->comment("药物种类：1西药 2中药 3中西药");
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('st_medical_medical_drug_type');
    }
}
